<template>
  <li class="v-dropdown-menu__item"
    :class="{
      'is-disabled': disabled,
      'v-dropdown-menu__item--divided': divided
    }"
    @click="handleClick">
    <slot></slot>
  </li>
</template>
<script>
  import Emitter from '@/vuego/mixins/emitter';

  export default {
    name: 'VDropdownItem',
    mixins: [Emitter],
    props: {
      command: {},
      disabled: Boolean,
      divided: Boolean,
    },
    methods: {
      handleClick() {
        this.dispatch('ElDropdown', 'menu-item-click', [this.command, this]);
      },
    },
  };
</script>
